package com.yn.xr.common.exception;


import com.yn.xr.common.constants.ExceptionErrorCodeDef;
import com.yn.xr.common.exception.base.BaseException;
import com.yn.xr.common.properties.PropertyConfig;
import com.yn.xr.common.util.StringUtils;
/**
 * 用户注册错误抛出异常
 */
public class UserRegistException extends BaseException {
	
	private static final long serialVersionUID = -5104739016997578463L;

	public UserRegistException(short errorCode,String errorMsg) {
		super(errorCode, StringUtils.isEmpty(errorMsg)?PropertyConfig.getValueBykey(String.valueOf(ExceptionErrorCodeDef.USER_REGIST_ERROR)):errorMsg);
	}
	
	public UserRegistException(String errorMsg) {
		super(ExceptionErrorCodeDef.USER_REGIST_ERROR, StringUtils.isEmpty(errorMsg)?PropertyConfig.getValueBykey(String.valueOf(ExceptionErrorCodeDef.USER_REGIST_ERROR)):errorMsg);
	}
	
	public UserRegistException() {
		super(ExceptionErrorCodeDef.USER_REGIST_ERROR, PropertyConfig.getValueBykey(String.valueOf(ExceptionErrorCodeDef.USER_REGIST_ERROR)));
	}
	
}
